From 5b6313f16f508882a0ea67716b7dbaa1c6967f04 Mon Sep 17 00:00:00 2001 From: dujinkim Date: Mon, 30 Jun 2025 08:28:13 +0000 Subject: (대표님) 20250630 16시 - 유저 도메인별 라우터 분리와 보안성검토 대응 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../engineering/(engineering)/items-tech/page.tsx | 67 ++++++++++++++++++++++ 1 file changed, 67 insertions(+) create mode 100644 app/[lng]/engineering/(engineering)/items-tech/page.tsx (limited to 'app/[lng]/engineering/(engineering)/items-tech/page.tsx') diff --git a/app/[lng]/engineering/(engineering)/items-tech/page.tsx b/app/[lng]/engineering/(engineering)/items-tech/page.tsx new file mode 100644 index 00000000..55ac9c63 --- /dev/null +++ b/app/[lng]/engineering/(engineering)/items-tech/page.tsx @@ -0,0 +1,67 @@ +import * as React from "react" +import { type SearchParams } from "@/types/table" + +import { getValidFilters } from "@/lib/data-table" +import { DataTableSkeleton } from "@/components/data-table/data-table-skeleton" +import { shipbuildingSearchParamsCache, offshoreTopSearchParamsCache, offshoreHullSearchParamsCache } from "@/lib/items-tech/validations" +import { getShipbuildingItems, getOffshoreTopItems, getOffshoreHullItems } from "@/lib/items-tech/service" +import { OffshoreTopTable } from "@/lib/items-tech/table/top/offshore-top-table" +import { OffshoreHullTable } from "@/lib/items-tech/table/hull/offshore-hull-table" + +// 대소문자 문제 해결 - 실제 파일명에 맞게 import +import { ItemsShipTable } from "@/lib/items-tech/table/ship/Items-ship-table" + +interface IndexPageProps { + searchParams: Promise +} + +export default async function IndexPage({ searchParams }: IndexPageProps) { + const params = await searchParams + const shipbuildingSearch = shipbuildingSearchParamsCache.parse(params) + const offshoreTopSearch = offshoreTopSearchParamsCache.parse(params) + const offshoreHullSearch = offshoreHullSearchParamsCache.parse(params) + const validShipbuildingFilters = getValidFilters(shipbuildingSearch.filters || []) + const validOffshoreTopFilters = getValidFilters(offshoreTopSearch.filters || []) + const validOffshoreHullFilters = getValidFilters(offshoreHullSearch.filters || []) + + + // URL에서 아이템 타입 가져오기 + const itemType = params.type || "ship" + + return ( +
+ {itemType === "ship" && ( + result)} + /> + )} + + {itemType === "top" && ( + result)} + /> + )} + + {itemType === "hull" && ( + result)} + /> + )} +
+ ) +} -- cgit v1.2.3